package com.pet.client.common;

import java.util.List;
import com.pet.framework.util.BaseAction;
import com.pet.framework.util.Config;
import com.pet.framework.util.FrameCache;
import com.pet.server.bo.system.AdminService;
import com.pet.server.po.MenuInfo;
import com.pet.server.po.SysUser;
import com.pet.system.constants.BaseAttribute;
import com.pet.system.util.SessionHelper;

public class AdminAction extends BaseAction {
	private Integer userId;
	private AdminService adminService;
	private String status,type;
	private Integer id;
	public Integer getId() {
		return id;
	}
	public void setId(Integer id) {
		this.id = id;
	}
	public String getStatus() {
		return status;
	}
	public void setStatus(String status) {
		this.status = status;
	}
	public Integer getUserId() {
		return userId;
	}
	public void setUserId(Integer userId) {
		this.userId = userId;
	}
	public AdminService getAdminService() {
		return adminService;
	}
	public void setAdminService(AdminService adminService) {
		this.adminService = adminService;
	}
	
	public String home(){
	
		SysUser user = SessionHelper.getSysUser();
		List<MenuInfo> list = FrameCache.getInstance().getMenuCacheByRole(user.getRoleInfo().getRoleId());
		setAttr(BaseAttribute.LIST, list);
		return SUCCESS;
	}
	public void reloadConfig(){
		Config.tag=false;
	}
	
	
	public String getType() {
		return type;
	}
	public void setType(String type) {
		this.type = type;
	}
	
	
	
}
